Skip to content

MINOR: Write bootstrap checkpoint only to metadata directories#22418

Open
majialoong wants to merge 1 commit into
apache:trunkfrom
majialoong:bootstrap_checkpoint_only_metadata
Open

MINOR: Write bootstrap checkpoint only to metadata directories#22418
majialoong wants to merge 1 commit into
apache:trunkfrom
majialoong:bootstrap_checkpoint_only_metadata

Conversation

@majialoong
Copy link
Copy Markdown
Contributor

This patch ensures the storage formatter writes the bootstrap checkpoint only to metadata directories, avoiding unexpected __cluster_metadata-0 directories in pure data log directories when formatting multiple directories in KRaft mode.

Copy link
Copy Markdown
Collaborator

@m1a2st m1a2st left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test on my local machine: TC_PATHS="tests/kafkatest/tests/tools/log_compaction_test.py" /bin/bash tests/docker/run_tests.sh

SESSION REPORT (ALL TESTS)
ducktape version: 0.12.0
session_id:       2026-05-29--001
run time:         7 minutes 11.601 seconds
tests run:        8
passed:           8
flaky:            0
failed:           0
ignored:          0

@majialoong
Copy link
Copy Markdown
Contributor Author

My local test:

TC_PATHS="tests/kafkatest/tests/tools/log_compaction_test.py" \
/bin/bash tests/docker/run_tests.sh
================================================================================
SESSION REPORT (ALL TESTS)
ducktape version: 0.14.0
session_id:       2026-05-29--002
run time:         7 minutes 32.823 seconds
tests run:        8
passed:           8
flaky:            0
failed:           0
ignored:          0
================================================================================
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=
status:     PASS
run time:   56.480 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.gzip.level.1
status:     PASS
run time:   56.151 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.gzip.level.9
status:     PASS
run time:   57.230 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.lz4.level.1
status:     PASS
run time:   56.372 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.lz4.level.10
status:     PASS
run time:   56.203 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.snappy
status:     PASS
run time:   56.493 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.zstd.level.1
status:     PASS
run time:   56.556 seconds
--------------------------------------------------------------------------------
test_id:    kafkatest.tests.tools.log_compaction_test.LogCompactionTest.test_log_compaction.metadata_quorum=ISOLATED_KRAFT.compression_config=.type.zstd.level.10
status:     PASS
run time:   56.289 seconds
--------------------------------------------------------------------------------

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

ci-approved kraft small Small PRs triage PRs from the community

Projects

None yet

Development

Successfully merging this pull request may close these issues.

3 participants